<template>
    <h3 :class="classobj">class绑定</h3>
    <div :class="[activeClass, errorClass]">class绑定</div>
</template>
<script>
    export default{
        data(){
            return{
                isActive:false,
                isDanger:true,
                classobj:{
                    'active':true,
                    'text-danger':true

                },
                activeClass:"active",
                errorClass:"text-danger"
            }
        }
    }
</script>
<style scoped>
.active{
    font: 1em sans-serif;
    color: #e42626;

}
.text-danger{
    font-size: 50px;
}
</style>